home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 18 / CU Amiga Magazine's Super CD-ROM 18 (1997)(EMAP Images)(GB)[!][issue 1998-01].iso / CUCD / Online / CNetDemo / cnet / sdk / include / ports.h < prev    next >
Encoding:
C/C++ Source or Header  |  1997-09-04  |  26.5 KB  |  840 lines

  1.  
  2. #ifndef CNET_PORTS
  3.    #define CNET_PORTS
  4.  
  5.    #ifndef CNETPORT
  6.       #define CNETPORT "cnetport"
  7.    #endif
  8.  
  9. #define MAILTASKPORT "cnmail_serv"
  10. #define FILETASKPORT "cnfile_serv"
  11. #define YANKTASKPORT "cnyank_serv"
  12. #define NEWSTASKPORT "cnnews_serv"
  13. #define USEREDPORT   "cnusered_port"
  14. #define MIMEEDPORT   "mimeed_port"
  15.  
  16.  
  17. #define TASK_REPOSICON_MSG      0x01 // CMessage.command sent to #?-task to tell them to reposition icon
  18. #define CONTROL_REPOSICON_MSG   0x06 // CMessage.command sent to Control to tell it to reposition icon
  19.  
  20.  
  21. #include "ranges.h"
  22. #include "users.h"
  23. #include "doors.h"
  24. #include "mail.h"
  25. #include "lists.h"
  26. #include "links.h"
  27. #include "telnet.h"
  28.  
  29. // 9/11/95 Length = 140
  30.  
  31. struct CNetPort {
  32.    char   UserName[32];
  33.    char   From[32];
  34.    char   Area[32];
  35.    char   Action[32];
  36.  
  37.    ULONG   Baud;
  38.    ULONG   Logon;
  39.  
  40.    USHORT   Port;
  41.    USHORT   Access;
  42. };
  43.  
  44.  
  45. #define PORTRIGHT_HIDDEN   0x0001
  46. #define PORTRIGHT_MUFFLED   0x0002
  47. #define PORTRIGHT_CHATENABLE   0x0004
  48. #define PORTRIGHT_NOTHIDDEN   0x0008
  49. #define PORTRIGHT_NOTMUFFLED   0x0010
  50. #define PORTRIGHT_CHATDISABLE   0x0020
  51.  
  52. struct SerPort {
  53.    long   unit;
  54.    long   flags;
  55.  
  56.    short   idlebaud;
  57.    short   escape;
  58.    short   answerpause;
  59.    short   seconds;
  60.  
  61.    char   name[21];
  62.    char   init1[50];
  63.    char   ppass[11];
  64.    char   init2[50];
  65.  
  66.    ULONG   TrapHours;
  67.    ULONG   MailHours;
  68.  
  69.    UBYTE   extra[3];
  70.  
  71.    char   hangup[21];
  72.    char   dialout[21];
  73.    char   answer[21];
  74.    char   offhook[21];
  75.    char   terminal[50];
  76.    char   callerid[11];
  77.    char   ring[9];
  78.    char   connect[11];
  79.  
  80.    char   termlink[21];
  81.  
  82.    UBYTE   other[2];
  83.  
  84.    UBYTE   null;      /* local terminal, no clear line */
  85. };
  86.  
  87.  
  88. // revised 22-Jan-97!
  89. struct SerPort4 {
  90.    long   unit;
  91.    long   flags;
  92.  
  93.    short   idlebaud;
  94.    short   escape;
  95.    short   answerpause;
  96.    short   seconds;
  97.  
  98.    char   name[40];
  99.    char   init1[50];
  100.    char   ppass[11];
  101.    char   init2[50];
  102.  
  103.    ULONG   TrapHours;
  104.    ULONG   MailHours;
  105.  
  106.    char   hangup[21];
  107.    char   dialout[21];
  108.    char   answer[21];
  109.    char   offhook[21];
  110.    char   terminal[50];
  111.    char   callerid[11];
  112.    char   ring[9];
  113.    char   connect[11];
  114.  
  115.    char   termlink[21];
  116.    UBYTE   null;        // local terminal, no clear line
  117.  
  118.    char IdleWho[21];    // 18-Feb-97 - text displayed in the "Handle/Name" area of who for idle port(s)
  119.  
  120.    long   portflags;    // 23-Apr-97
  121.                         // bits: &1 = show port on WHO display.  if bit not set, do not show port on WHO
  122.                         //       (other bits currently unused)
  123.  
  124.    BYTE expansion[103];
  125. };
  126.  
  127. struct PortData {                   // each opened ports global vars
  128.    struct   IsDate   Today;         // 0 what time is it right now?
  129.    struct   IsDate   VConnectDate;  // 6 Virtual connect...eg 12am
  130.  
  131.    short   id,                      // 12 current user1 account #
  132.       InPort,                       // 14 which port are we in?? 
  133.       Age,                          // 16 how old am I ?
  134.       CurrentCPS,                   // 18 CPS rate.  240 == 2400 baud
  135.       OnType,                       // 20 type of logon 
  136.       OffType,                      // 22
  137.       CallMessages,                 // 24
  138.       CallFeedbacks,                // 26
  139.       TimeLeft,                     // 28 TENTHS of minutes left
  140.       TimeIdle,                     // 30 TENTHS of minutes without activity
  141.       TimeOnLine,                   // 32 TENTHS of minutes since logon
  142.       TimeCredit,                   // 34 TENTHS awarded for uploads, etc
  143.       LastTSR,                      // 36
  144.       Carrier;                      // 38 Is there a carrier or Local?
  145.  
  146.    char   *AName;                   // 40 ptr to access group name
  147.    long   SysMaint,                 // 44
  148.       LocalTime,                    // 48 current area sur-time minutes
  149.       LocalCharge,                  // 52 current area sur-charge per minute
  150.       LastTime,                     // 56
  151.       ServLen,                      // 60 seconds in-between Service() calls
  152.       Caller;                       // 64 which caller am I?
  153.  
  154.    struct   UserData   user1,       // 68
  155.             user2;                  // 740 actual user structs
  156.  
  157.    short   MyMail;                  // 1412 counters for user currently online
  158.    short   MyNewMail;               // 1414
  159.    short   bn;                      // 1416 current sub #
  160.  
  161.    char   CallerID [18];            // 1418 Received from Supra, prev connect
  162.    short   CIDmatch [ 8];           // Accounts which MATCH, [0] will be current user 
  163.  
  164.    UBYTE InFeedback;                // 1436 TRUE (1) if user is sending feedback - used to skip mail send flag prompt
  165.  
  166.    UBYTE NoClearIBuff;              // 1437 TRUE = add '/' to input buffer rather than use for buffer clearing operation 
  167.    UBYTE NoSpaceAbort;              // 1438 TRUE = add SPACE to input stream rather than use as abort character
  168.    UBYTE NoCaseConvert;             // 1439 TRUE = do not convert input from OneKey() to uppercase
  169.    UBYTE   expansion[14];           // 1439
  170.  
  171.    UBYTE   PAccess,                 // 1470
  172.       RAccess,
  173.       DAccess,
  174.       UAccess;
  175.  
  176.    char   fsuff[8],                 // 1474 more header stuff
  177.       fcore[32],                    // 1482
  178.       Title[80],                    // 1514 Screen/Window Title
  179.       lastby_NOT[36];               // 1594 moved to struct PortDataExtension
  180.  
  181.    UBYTE   IUCBits[100];            // 1630 Hidden, Muffled, Monitor, ChatReq
  182.  
  183.    char   *MyDoing;                 // 1730
  184.    struct   Room *CRoom;            // 1734 which room am I in ?
  185.    struct   RoomUser *CUser;        // 1738 where is my RoomUser struct
  186.  
  187.    UBYTE   Dumped,                  // 1742 auto-kickoff flag
  188.       OLMWaiting,                   // 1743 OLM waiting   
  189.       HideAll,                      // 1744 Hidden from ALL?
  190.       MuffAll,                      // 1745  Muffling ALL?
  191.       MonitorAll,                   // 1746 Monitoring ALL?
  192.       OnLine,                       // 1747
  193.       nPdepth,                      // 1748 How many pfiles a port is running
  194.       ChatCode,                     // 1749 who's chatting with whom
  195.       WantToOpen,                   // 1750
  196.       getout,                       // 1751 flag to auto-quit port
  197.       loaded,                       // 1752 Is this port loaded?
  198.       other[3];                     // 1753
  199.  
  200.    long   LastEvent,                // 1756 keep track of the last event
  201.       LastCut,                      // 1760 time in these 4 catagories
  202.       LastHold,                     // 1764
  203.       LastOnLine;                   // 1768
  204.  
  205.    long   TempSysMaint;
  206.    short   ConfIdle;
  207.  
  208.    struct NewMailFolder *Folders;   // 1778 - linked list of mail folders - may not be loaded until MailRead or MailSend
  209.    struct NewMailFolder *Folder0;   // 1782 - pointer to folder currently in use
  210.  
  211.    struct MailHeader4 *rmhead;      // 1786 - linked list of mail header pointers allocated during mail read - mail only allocated for the currently "open" folder
  212.    struct MailAlias *Aliases;       // 1790 - linked list of mail aliases - may not be loaded until MailRead/MailSend
  213.  
  214.    ULONG   DOIO_MASK;               // 1794
  215.    struct   IOStdReq    *DoReq;     // 1798
  216.    struct   MsgPort      *DoPort;   // 1802
  217.  
  218.    long   uz[10];                   // 1806 for C programmer use.  You can
  219.                                     // (typecast) them as you need to
  220.  
  221.    struct   Task      *ThisTask;
  222.    struct   MainPort   *cnp;
  223.  
  224.    struct   Window      *Window, *CWindow, *SWindow, *TWindow,
  225.             *TTWindow, *WBWindow;
  226.    struct   Screen      *Screen;
  227.    struct   RastPort   *wrp, *trp;
  228.    struct   TextFont   *BlueFont,
  229.             *StandardFont;
  230.    struct   IOStdReq    *UTReq, *ServReq, *PrintReq, *ConReq;
  231.    struct   IOExtSer   *SerRdReq, *SerWrReq, *SerIOReq;
  232.    struct   MsgPort      *SerRdPort,*SerWrPort,*SerIOPort, *ConPort,
  233.             *UTPort,   *ServPort, *PrintPort, *cpreplyp;
  234.  
  235.    struct   FileInfoBlock   *fib;   // for reading directories
  236.    struct   InfoData   *IData;      // for getting free disk space, etc
  237.    struct   AnchorPath   *ap;
  238.    struct   MessageType3    *Message;
  239.    struct   BaseUser   *buser;
  240.    struct   SelectType      *Select;
  241.    struct   BaseUser   *brec;
  242.    struct   SelectType   *Upload;
  243.    struct   ListItem        *fpt;
  244.    struct   ItemHeader   **ih, *ihead_obs;
  245.    struct   ItemType3   **ip;
  246.    char   **EdBuffer;               // pointers to editor lines
  247.    char   *EdBase;                  // pointer to editor memory
  248.    UBYTE   *CR;                     // Is there a Carriage Return? ea lin
  249.    char   **mm;                     // pointers to bbsmenu lines
  250.    char   **bm;                     // pointers to bbstext lines
  251.    short   *menustart;
  252.    short   *menulen;
  253.  
  254.    long   plsize, nplanes;          // SkyStuff Stuff
  255.    short   skyxpen, skyypen;
  256.    PLANEPTR planePtr;
  257.    struct   TmpRas      tmpRas;
  258.    struct   BitMap     SkyBrush;
  259.  
  260.    long   FullMaint;
  261.  
  262.    long   numWE;                    // window-edit, current number
  263.    long   WWidth;                   // 80
  264.    long   WLength;                  // 24
  265.    long   WLeft;                    // def   0
  266.    long   WRight;                   // def 639
  267.    long   WTop;                     // def  11
  268.    long   WBottom;                  // def YMAX
  269.  
  270.    short   xc,                      // x coord, cursor pos
  271.       yc,                           // y coord
  272.       sxc,                          // storage for ANSI [s, [t
  273.       syc,
  274.       YMAX,                         // max y value
  275.       CurrentMouseX,
  276.       CurrentMouseY,
  277.       countWE;                      // window-edit, # characters
  278.       
  279.    short   IsHalfScreen;
  280.    short   TermLength;
  281.  
  282.    short   SWidth;
  283.    short   SHeight;
  284.    short   DWidth;
  285.    UBYTE   io_bad;
  286.    UBYTE   io_status;               // debugging Supra hangs
  287.  
  288.    char   *by0,                     // scan and header variables
  289.       *by1,                         // for MCI configurability
  290.       *to0,
  291.       *to1,
  292.       *date0,
  293.       *organ,
  294.  
  295.       plus[2],
  296.       star[2],
  297.       fdate[8],
  298.       fsize[8],
  299.       ftime[12],
  300.       *title0,
  301.       *olm_default,
  302.       *vis_subj,
  303.       *vis_to,
  304.       *user_default,
  305.       *subj_default;
  306.  
  307.    short   Depth;
  308.    short   DHeight;
  309.  
  310.    short   TextSet;                 // 0==use system-wide text/menu
  311.    short   npitems;                 // number of items parsed
  312.    char   pitem[8][61];             // last input parsed list
  313.  
  314.    long   txline;                   // number of lines in ed buffer
  315.    char   GBuffer[16][81];          // General purpose 2-D text buffer
  316.    UBYTE   GCR[16];
  317.  
  318.    ULONG   WaitFlags,
  319.       SERVICE_MASK,
  320.       RAWKEY_MASK;
  321.  
  322.    struct   JobType4 *pEvents;      // 4062 - list of waiting port events - queued events are Loaded when port is up and running
  323.  
  324.    struct SignalSemaphore pesem;    // 4066 - semaphore (46 bytes long) for locking pevents (port events) list
  325.    struct SignalSemaphore mfsem;    // 4112 - semaphore (46 bytes long) for locking Folders list
  326.  
  327.    ULONG   eventtick;               // 4158 - events are ticking
  328.    ULONG   nextevent;               // 4162 - time next event for this port - in seconds
  329.  
  330.    struct   SignalSemaphore sem;    // 4166
  331.    LONG nothing171196;              // 4212 - ordered listing (pointers) of items in door/list areas
  332.  
  333.    struct   MailHeader4 *POMail0;   // 4216 - pointer into z->rmhead - current message being read, edited or verified
  334.    struct   ChargeSet  *NowCharge;
  335.  
  336.    long   CTC[80];                  // users account, 62 items, Cost of This Call
  337.  
  338.    short   sorder[240];             // max subboards per subdir is 240
  339.                                     // ^^ needs to be changed to use DYNAMIC allocation
  340.                                     // so it can bypass limit of 240!
  341.  
  342.    char   *LastError;               // for file transfer WHY command
  343.  
  344.    char   RexxObject  [100],
  345.          KBuff       [256],         // keyboard buffer!
  346.  
  347.          *ABuffer;                  // 15-Apr-97 -> ABuffer now allocated dynamically at startup
  348.                                     // (size of ABuffer now CONFIGURABLE via Config/Limits!)
  349.  
  350.    BYTE AB_expansion[252];          // got some nice expansion room by making ABuffer dynamic!
  351.  
  352.    char InBuffer    [256];          // after a line input
  353.       
  354.    char   rbyname[40];              // 29-Aug-96 .. handle/name to look for if name in "read mess by handle/name" is not local
  355.  
  356.    char def_mailsubj[81];           // 30-Aug-96 .. default mail subject for new mails. Set using ARexx "SetMailSubject"
  357.  
  358.    char   rtoname[40];              // 22-Sep-96 .. handle/name to look for if name in "read mess to handle/name" is not local
  359.  
  360.    struct PortDataExtension *PDE;   // NEW extension to PortData!! 18-Oct-96 - to be added as structure type 3 in GETUSER list
  361.  
  362.    UBYTE DizShort;                  // 17-Feb-97 .. TRUE if using [W]rite to write file short description
  363.  
  364.    char  Expansion290896[197];      // last changed 18-Oct-96
  365.  
  366.    char   Doing     [48],
  367.       SPrompt     [128],            // subboard prompt
  368.       LPrompt     [128],            // G/P/N list prompt
  369.       ldiskloc    [160],            // diskloc for P/G/N
  370.       myloc       [164],            // for Read-Mail
  371.       filename    [116],
  372.       ListArea     [40],
  373.       rsearch      [64],
  374.       myfile       [54],
  375.       dirname      [32],
  376.       CStack       [80],            // Command stacking
  377.       ChatMsg      [84],            // current chat message
  378.       sbuff        [48],
  379.       outbuffer    [84],
  380.       ansiout     [164],
  381.       ConnectCode  [84],
  382.       ChatBuff     [84],
  383.       APrint       [36],            // for PrintAccess
  384.       PName     [3][32],
  385.       home         [36],
  386.       qwk_to       [28],
  387.       qwk_subject  [28],
  388.       BackBuff [10][80],            // last 10 commands executed
  389.       Pathx     [8][64];            // g/p/n subdir history
  390.  
  391.    long   bbnum;                    // pointer into D-Q
  392.  
  393.    long   warn1;
  394.  
  395.    long   TotalCTC;                 // TOTAL Cost of this Call (100ths
  396.  
  397.    short   bz,                      // # of subs on current List
  398.       dz,                           // how deep in the tree are we?
  399.       br,                           // item last used
  400.       rn_obs,                       // how many items, current list
  401.  
  402.       nl,                           // number on g/p/n list
  403.       allin_obs,                    // Are all items in memory?
  404.       VTimeOnLine,                  // may reset at midnight
  405.       PTimeOnLine,                  // in-current-pfile time counter
  406.  
  407.       mx,                           // highest item NOT killed
  408.       listn,                        // current list subboard pointer
  409.       parent0,
  410.       gpos,                         // for global commands, last command #
  411.  
  412.       nsubs,                        // tracks # subs accessed in a Global cmd
  413.       LinkPort;
  414.  
  415.    long   TermLinkBaud;
  416.  
  417.    char   *mygokeyword;             // go keyword for user's current location   - if 0, user is at main menu aka root object list
  418.  
  419.    long   rs,                       // were once SHORTS...moved here to
  420.       cpos,                         // avoid conflicts with 32767 max  
  421.       mstart,
  422.       mend,
  423.       new_i,                        // responses/item or per subboard 
  424.       new_n,
  425.       new_f,
  426.       new_p,
  427.       new_ri,
  428.       t_new_i,                      // total new items
  429.       t_new_n,                      // total new messages to you
  430.       t_new_f,                      // total new files
  431.       t_new_p,                      // total new posts
  432.       t_new_ri;                     // total new response items
  433.  
  434.    USHORT   AParams,
  435.       AParam[17];
  436.  
  437.    UBYTE   qwk;
  438.    UBYTE   ylharc;
  439.    UBYTE   yaddcr;
  440.    UBYTE   ylocal;
  441.  
  442.    short   zmatches;
  443.    UBYTE   zheader;
  444.    UBYTE   readnew;
  445.  
  446.    long   nsets,
  447.       rset,
  448.       rcount,
  449.       rtotal,
  450.       set[10][2];
  451.  
  452.    UBYTE   runseen,
  453.       resetIP,                      // flag, must re-order item pointers
  454.       atbase,
  455.       TermLink,
  456.  
  457.       rtome,
  458.       rfree,
  459.       rfavorite,
  460.       runval,
  461.  
  462.       rprivate,
  463.       rreverse,
  464.       rbrandnew,
  465.       rnresponse,
  466.  
  467.       rpass,
  468.       rsince,
  469.       rnew,
  470.       rglobal,
  471.  
  472.       rdeftype,
  473.       rchron,
  474.       rbyme,
  475.       runtil,
  476.  
  477.       rjustposts,
  478.       rpreview,
  479.       rbanner,
  480.       rjustfiles;
  481.  
  482.    struct   IsDate   rdate,
  483.          udate;
  484.  
  485.    short   pos,
  486.       num,
  487.  
  488.       rdelta,                       // for/back n items
  489.  
  490.       NoSelected,                   // number of items in Select List
  491.       NoUploaded,
  492.       ModelType;                    // Controls .M in editor. 
  493.  
  494.    struct   RangeContext EdRange;
  495.  
  496.    long   tline, bit_mci;
  497.    short   times, repmode, MaxLines, WScroll;
  498.  
  499.    long   warn2;
  500.  
  501.    char   keyin,
  502.       edall_not,                    // allow enterline all chars
  503.       serbuffer[2];
  504.  
  505.    UBYTE   mode,
  506.       ZAlternate,
  507.       CheckAllEvents,               // force check of TimeTilEvent's
  508.       TrapDoor,
  509.  
  510.       AtPrompt,
  511.       InShell,
  512.       donormal,
  513.       dtr,                          // modem device OPENED and ready
  514.  
  515.       sread,                        // read request pending ...
  516.       modem,                        // modem exists ... allows BBSPORT0
  517.       mio,                          // modem IO allowed
  518.       isud_not,
  519.  
  520.       MaxColors,                    // # of colors on screen
  521.       FlagCH,
  522.       FlagED,
  523.       Gflag,
  524.  
  525.       ConfMode,                     // Are we in conference?
  526.       column,
  527.       KB1,                          // DeQueue pointers
  528.       KB2,
  529.  
  530.       KB3,                          // what inter-user chat sees
  531.       CursorStatus,                 // is cursor on?
  532.       AbortFlags,
  533.       HourNow,
  534.  
  535.       LastHour,
  536.       Indent,
  537.       InANSI,
  538.       GETarg,
  539.  
  540.       CMDarg,
  541.       LocalMode,                    // BOOLS .. In Local Mode ?
  542.       noflowcontrol,
  543.       AtWaitScreen,                 // Are we at IDLE?
  544.  
  545.       InMCI,
  546.       DoQuick,                      // ! at last input ?
  547.       AutoLogon,
  548.       TermOn,                       // in terminal?
  549.  
  550.       ANSIon,                       // can we type ansi? (ESC)
  551.       PrintFlags,                   // space or ^C pressed
  552.       CountUp,
  553.       InputFlags,
  554.  
  555.       Relogon,
  556.       Logoff,
  557.       NewScanBROWSE,                // BROWSE at logon scan for new?
  558.       AutoScroll,
  559.  
  560.       WWrap,
  561.       DoubleBuffer,
  562.       MoreRow,
  563.       MoreAtRow,
  564.  
  565.       WScreen,
  566.       InTransfer,
  567.       NoMCI,
  568.       FreezeTime,
  569.  
  570.       kolorific,
  571.       mciflash,                     // actually, bold
  572.       mciscore,
  573.       mcireverse,
  574.  
  575.       intense,                      // color greater than 7?
  576.       mciprint,
  577.       mcispeed,
  578.       mcicolor,                     // the requested MCI color 0-7
  579.  
  580.       pencolor,                     // actual screen pencolor
  581.       mcinoabort,
  582.       backcolor,                    // background color
  583.       mciback,
  584.    
  585.       MCIenv,                       // current MCI environ flags
  586.       MCIdefenv,
  587.       MRinuse,                      // mail/post office in use status bits
  588.                                     // eg. if((z->MRinuse & 1<<bit) == 1) to test.
  589.                                     // bit 3 = In post office
  590.                                     // bit 2 = in mailsend
  591.                                     // bit 1 = in mailread
  592.  
  593.       OffLine,                      // skip answering the phone??
  594.  
  595.       cminute, 
  596.       chour,
  597.       FNewSave,                     // flag: update FNewDate at logoff
  598.       intab;                        // for LoadLine()
  599.  
  600.    char   mcitest,                  // MCI stuff
  601.       EditorOn,                     // is editor on?
  602.       var5,
  603.       ScreenWidth;
  604.  
  605.    long   warn3;
  606.  
  607.    long   swrite, LogoffFlag;       // file transfer stuff
  608.    long   ResumeSize;
  609.    short   ResumeNumber, StartUpTime;
  610.  
  611.    short   protonum;
  612.    char   protobyte;
  613.    char   edbuff;                   //   1 saved new text
  614.                                     //   0 saved empty buffer
  615.                                     //   -1 aborted
  616.  
  617.  
  618. //   If you use QuoteType=2, you MUST set the following three variables
  619. //   Note that QuoteFrom and QuoteDate are POINTERS ... do NOT copy into
  620. //   them!
  621.  
  622.    char   *QuoteFrom;               // Who are we quoting?
  623.    struct   IsDate *QuoteDate;      // When was that message written?
  624.    long   QuoteEnd;                 // LAST BYTE position in file
  625.                                     // Quoter will stop automatica
  626.                                     //   if ^Z occurs first
  627.    UBYTE   qwk_anonymous;
  628.    UBYTE   qwk_private;
  629.    short   xfercount;
  630.  
  631.    long   XferTime;
  632.    long   LastCPS,
  633.          cpsavecount;
  634.    long   cpsavesum,
  635.          LastXTime,
  636.          StartByte,
  637.          LastByte;
  638.  
  639.    short   ARunCount;               // depth of AREXX pfiles
  640.    short   CRunCount;               // depth of C pfiles
  641.    char   CSpawn[84];
  642.  
  643.    long   TrapBaud;
  644.    long   TrapLock;
  645.  
  646.    UBYTE   QuoteType;               // 0==Mail, 1==Message b
  647.                                     //   2==User defined.  See QuoteFrom,
  648.                                     //   QuoteDate, etc., above */
  649.    char   QuotePath[103];           // MESSAGE QUOTING in editor.
  650.                                     // SETTING this ENABLES quoti
  651.                                     //   Remember to QuotePath[0] = 0 after
  652.                                     //   you use it.
  653.    long   QuoteSeek;                // What's the starting byte pos?
  654.  
  655.    short   imode;                   // editor.  Insert mode?  If yes, which lin
  656.    short   iline;
  657.  
  658.    long   abort;
  659.  
  660.    short   UrgentMail1;
  661.    char   ExtTransfer;
  662.    char   ExtProtocol;
  663.  
  664.    long   ExtMinFree;
  665.  
  666.    long   ALogon;
  667.    long   BLogon;
  668.    long   ATransfer;
  669.    long   BDownload;
  670.    long   BUpload;
  671.    long   APfiles;
  672.    long   BCharge;
  673.    long   hiCharge;
  674.    long   loCharge;
  675.  
  676.    long   rtoid;                    // to 'handle' searches
  677.  
  678.    long   TimeTilOnLine,
  679.       TimeTilCutoff,                // Log user off first event
  680.       TimeTilEvent,                 // Immediate (regular) event
  681.       TimeTilHold;                  // hold until off-line event
  682.  
  683.    long   SERIAL_MASK,
  684.       UTILITY_MASK;
  685.  
  686.    char   *xpr_filename;
  687.  
  688.  
  689.    UBYTE   xpr_obsolete[124];
  690.  
  691.  
  692.    struct   MsgPort *rexxPort;
  693.    long   rexxPortBit;
  694.    char   *extension;
  695.    struct   rexxCommandList *globalrcl;
  696.  
  697.    UBYTE   callback,                // enable AUTOCALLBACK @ LOGON
  698.       avalid,                       // which avalid set to use
  699.       joinlink,                     // 0==off, 1==accept, 2==accept ONLY
  700.       FreezeIdle;                   // special use -- stop idle timer
  701.  
  702.    long   rbyid;                    // by 'handle' searches
  703.  
  704.    long   SAMNow[20];               // users 'Last' SAM column
  705.  
  706.    struct   CMessage   cpmess;
  707.  
  708.    BYTE      RRM_trig;              // true if user performed Repair_mail
  709.                                     // on this port and mail needs to rescan
  710.  
  711.    BYTE      was_SerPort[347];      // WAS SERPORT data. see above struct
  712.                                     // moved to PortDataExtension!
  713.  
  714.    struct   BaseUser   xbrec;
  715.    struct   ItemType3   Item0;
  716.    struct   ItemHeader   ihead0;
  717.    struct   HeaderType   Header0, LastHeader;
  718.    struct   OldMailHeader   OMail0_NOT;
  719.    struct   SelectType   Select0;
  720.    struct   MessageType3   Message0;
  721.  
  722.    UBYTE   Subdir_NOT [172];
  723.  
  724.    struct   SubboardType4 *sb;
  725.  
  726.    char   rpattok[202];             // tokenized search pattern
  727.  
  728.    UBYTE   Subboard0_NOT [276];
  729.  
  730.    short   WBorTop;
  731.    short   nupload;                 // # of upload allocated   
  732.    short   nips_obs;
  733.  
  734.    short   Monitored;               // 128 + port number if monitored.
  735.    short   ModelEnable;             // Controls .M in editor. 
  736.  
  737.    BPTR   MCIfile;
  738.    long   mcilabel;
  739.    long   nlabels;
  740.    long   mlabel[20];
  741.    long   mfseek[20];
  742.    long   MCInreg[10];
  743.    char   MCIcreg[ 5][100];
  744.  
  745.    BPTR   sf;                       // for _short scan
  746.    long   sfin;
  747.  
  748.    long   VoteItem;                 // which vote? -1==New
  749.    char   *VotePath;                // for Vote in Any Area!
  750.  
  751.    UBYTE   q_kolorific,             // MCI Q2/Q3 storage
  752.       q_mciflash,
  753.       q_mciscore,
  754.       q_mcireverse,
  755.  
  756.       q_intense,
  757.       q_mciprint,
  758.       q_mcispeed,
  759.       q_mcicolor,
  760.  
  761.       q_mciback,
  762.       q_mcinoabort,
  763.       q_MCIenv;
  764.  
  765.    UBYTE   SelectInMemory;          // is _select in memory or on disk?
  766.  
  767.    struct   Event   *FirstEvent,
  768.          *FirstCutEvent,
  769.          *FirstHoldEvent,
  770.          *FirstOnLineEvent;
  771.  
  772.    struct   TermLink tl;
  773.  
  774.    char   JoinLinkOut[76];
  775.  
  776.    struct   VDEentry *vv;           // the currently loaded VDE file
  777.    short   vns;                     // used with VDEapply featuers! 
  778.    UBYTE   vmulti;                  // editing more than one?       
  779.    UBYTE   iselect;                 // is the input SELECTED?       
  780.  
  781.    char   gmPath[36];               // global Read-Mail variables...
  782.    ULONG   *gmPos;
  783.    ULONG   *gmNum;                  // needed for Yank command .... 
  784.    UBYTE   *gmFlags;
  785.  
  786.    UBYTE   *amem;                   // DrawEd variables
  787.    UBYTE   *cmem;
  788.    long   maxdraw;
  789.  
  790.    UBYTE   predraw;
  791.    UBYTE   GiveCPR;                 // CPR request received in term
  792.    UBYTE   hmmmm[2];
  793.  
  794.    UBYTE   *smem;
  795.  
  796.    long   inlen, edlength;
  797.  
  798.    UBYTE   invalid;
  799.    char FileNote[750];              // temp storage for "short" descriptions, DIZ and filenotes
  800.                                     // moved here to facilitate expansion - was 364 bytes previously
  801.  
  802.    // new for v4.12
  803.    struct MailHeader4   OMail0;     // general purpose mailheader (not a pointer!) - used for outgoing/incoming mail and mailread
  804.    struct SignalSemaphore masem;    // semaphore for locking Aliases list
  805.    struct SignalSemaphore rmhsem;   // semaphore for locking the mail header list
  806. };
  807.  
  808.  
  809. ////////////////////////////////////////////////////////////////////////////
  810. //
  811. //        PortData extensions!   (z->PDE)        ----      18-Oct-96
  812. //
  813. struct PortDataExtension {
  814.    struct TNHostEntry *TNHost0;       // pointer to telnet host entry in use during list/scan/edit of sysop/pre-configured hosts
  815.    struct TNHostEntry *CurrentTNHost; // pointer to telnet host entry currently connected to - NULL/0 if none/unique
  816.    LONG *GoMatches;                   // pointer to array of GO matches used in parsing GO keys
  817.    char *DynamicGoKey;                // go keyword currently displayed for GO arg listings
  818.    char *DynamicGoTitle;              // Title of currently displayed subboard in Go arg listing
  819.    LONG DynamicGoNum;                 // number (in current list) of Go arg
  820.    UBYTE InMailFwd;                   // TRUE if we are currently forwarding mail.
  821.    short def_part;                    // default partition to move files to (dynamic setting pertains to bbstext line 1778)..
  822.    short MailArrived;                 // number of new mails attached to online user's mailbox - set by mail-task
  823.  
  824.    // 9-Jan-97
  825.    char lastby[52];                   // moved here from previous GU offset
  826.                                       // of 1594 in struct PortData - expanded
  827.                                       // from 36 characters to 52 in length.
  828.  
  829.    struct SerPort4 sp;                // moved here from PortData!
  830. };
  831.  
  832.  
  833. // obsolete
  834. #define HIDDEN_FLAG   0x01
  835. #define MUFFLED_FLAG   0x02
  836. #define MONITOR_FLAG   0x04
  837. #define CHATREQ_FLAG   0x08
  838.  
  839. #endif
  840.